package net.huashitong.ssydt.provider.exam.service;


import net.huashitong.ssydt.exam.entity.SsExamArticleQuestionRecord;
import net.huashitong.ssydt.provider.exam.mapper.SsExamArticleQuestionRecordMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

/**
 * @author <a href="mailto:yhy23456@163.com">huiyang.yu</a>
 * @since 2017.10.30
 */
@Service
@Transactional
public class SsExamArticleQuestionRecordServiceImpl implements SsExamArticleQuestionRecordService {

    private SsExamArticleQuestionRecordMapper mapper;

    @Autowired
    public SsExamArticleQuestionRecordServiceImpl(SsExamArticleQuestionRecordMapper mapper) {
        this.mapper = mapper;
    }

    @Override
    public int deleteByPrimaryKey(Long id) {
        return mapper.deleteByPrimaryKey(id);
    }

    @Override
    public int insert(SsExamArticleQuestionRecord record) {
        return mapper.insert(record);
    }

    @Override
    public int insertSelective(SsExamArticleQuestionRecord record) {
        return mapper.insertSelective(record);
    }

    @Override
    public SsExamArticleQuestionRecord selectByPrimaryKey(Long id) {
        return mapper.selectByPrimaryKey(id);
    }

    @Override
    public int updateByPrimaryKeySelective(SsExamArticleQuestionRecord record) {
        return mapper.updateByPrimaryKeySelective(record);
    }

    @Override
    public int updateByPrimaryKey(SsExamArticleQuestionRecord record) {
        return mapper.updateByPrimaryKey(record);
    }

    @Override
    public List<SsExamArticleQuestionRecord> findByArticleRecordId(Long articleRecordId) {
        return mapper.findByArticleRecordId(articleRecordId);
    }

    @Override
    public int batchInsert(List<SsExamArticleQuestionRecord> questionRecords) {
        return mapper.batchInsert(questionRecords);
    }
}
